package com.xin.demo.springboot_xin_demo4.service.impl;

import com.xin.demo.springboot_xin_demo4.dao.ArticleMapper;
import com.xin.demo.springboot_xin_demo4.pojo.Article;
import com.xin.demo.springboot_xin_demo4.service.IArticleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class ArticleServiceImpl implements IArticleService {
    @Autowired
    private ArticleMapper articleMapper;
    @Override
    public List<Article> getArticles(Integer page, Integer limit) {
        List<Article> menuList = null;
        menuList = articleMapper.findAll();//分页查询执行mapper接口的方法
        return menuList;
    }
}
